﻿<template id="tree-template">
        <div class="row">
            <div class="col-xs-4 col-sm-3">
                <input class="form-control" v-model="name" placeholder="输入门店名" debounce="300" />
            </div>
            <div class="col-xs-4 col-sm-3">
                <input class="form-control" v-model="code" placeholder="输入门店编码" debounce="300" />
            </div>
            <div class="col-xs-4 col-sm-4">               
                <div class="input-group ">
                    <input type="text" class="form-control" placeholder="按择门店组筛选" v-model="groupName" disabled >
                    <input type="hidden" v-model="groupId" />
                    <div class="input-group-btn">
                        <button type="button" class="btn btn-default dropdown-toggle"  data-toggle="dropdown" aria-expanded="false" >
                            请选择
                            <span class="fa fa-caret-down"></span>
                        </button>
                        <button type="button" class="btn btn-default " title="清除条件" v-on:click="clear"><i class="fa fa-eraser"></i></button>
                        <ul class="dropdown-menu dropdown-menu-right" style="max-height: 300px; overflow:auto" >
                            <li>
                                <div class="input-group">
                                    <span class="input-group-addon"><i class="fa fa-search"></i></span>
                                    <input type="text" class="form-control" placeholder="搜索门店组" v-model="filterKey">
                                </div>
                            </li>
                            <li v-for="item in items | filterBy filterKey"><a href="#" v-on:click.prevent="selectItem(item)">{{item.name}}</a></li>
                        </ul>
                    </div>
                </div>
            </div>
        </div>
        <div class="row" style="min-height:350px;max-height:500px;overflow:auto;"><ul id="{{treeid}}" class="ztree"></ul></div>   
</template>
